# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=python-delegator.py
_pkgname=delegator.py
pkgver=0.1.1
pkgrel=8
pkgdesc='Subprocesses for Humans 2.0..'
url='https://pypi.org/project/delegator.py/#files'
arch=('any')
license=('MIT')
depends=('python')
makedepends=('python-pip' 'python-build' 'python-wheel')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.tar.gz")
sha512sums=('7af16f553fafc272056b1bd715ff41c821e0eeccfd6c5e5dcec819333373c9f7daaa95afe9b9aa796244f280869ccb1ddacb075b9fa196ed47a6699096abc143')

build() {
  cd "$_pkgname-$pkgver"

  python -m build --wheel --outdir="$startdir/dist"
}

package() {
  cd "$_pkgname-$pkgver"

  pip install \
    --verbose \
    --disable-pip-version-check \
    --no-warn-script-location \
    --ignore-installed \
    --no-compile \
    --no-deps \
    --root="$pkgdir" \
    --prefix=/usr \
    --no-index \
    --find-links="file://$startdir/dist" \
    $_pkgname
}

